	var target = document.getElementById("wrapper");
	touch.on(target, "touchmove", function(ev) {
		});
//===================下拉显示=================
touch.on($(".small_img"), "touchstart", function(ev) {
	
		$(".hide").show();  //下面隐藏div显示
	$(".small_img").css({"display":"none"});               
	$(".small_img_2").css({"display":"block"});
});
touch.on($(".small_img_2"), "touchstart", function(ev) {
	
		$(".hide").hide();  //下面隐藏div隐藏
	$(".small_img").css({"display":"block"});
	$(".small_img_2").css({"display":"none"});
});
//===================ajax请求=================================
						var str = "";
						var str_1 = "";
						var str_2 = "";
						var str_3 = "";
						var str_4 = "";
						$.ajax({
							type: "get",
							url: "../json/competition.json",
							data: {
								aid: "3c2c1673f45c4c7f9f7611006f998fe3",
								ps: "10",
								pn: 1
							},
							dataType: "json",
							beforeSend:function(){
								refresh();
							},
							complete:function(){
								$("#foo").css("display","none");
							},
							success: function(rsp) {
								str += '<img src="' + rsp.icon + '"/>';
								$(".swiper-container").html(str);
								str_1 += '<p class="team-name">' + rsp.name + '</p>';
								$(".team").html(str_1);
								str_2 += '<a>' + rsp.desc_info + '</a>';
								$(".team-information_2").html(str_2);
								str_4 += '<a href="###" class="recent_ganme_a">' + rsp.name + '</a>';
								$(".recent_ganme_a").html(str_4);
								for (var i = 0; i < rsp.list.length; i++) {
									str_3 += '<div class="competition_information"><div class="border-bottom_b"><div class="table"><ul class="table_1"><li>' + rsp.list[i].date + '</li><li class="table_1_1">常规赛</li></ul><ul class="table_2"><li>' + rsp.list[i].guestname + '</li><li class="table_2_1">VS</li><li class="table_2_2">' + rsp.list[i].hostname + '</li></ul><div class="subState"><input type="checkbox" id="' + rsp.list[i].hostid + '" class="check" checked="checked"/><label for="' + rsp.list[i].hostid +'" class="labsub"></label></div></div></div></div>';
								}
								$(".box").html(str_3);
								competion_sub();
								myscroll.refresh();
							   	var flag = true;	
							}
						});
//按钮延迟解决方案function() 
function competion_sub(){

	var oSubState = document.getElementsByClassName("subState");
	var oCheck = document.getElementsByClassName("check");
	var oLabsub = document.getElementsByClassName("labsub");
	for (var i = 0; i < oCheck.length; i++) {
		oCheck[i].index = i;
		oCheck[i].onclick = function() {
			if(!this.checked) {
				$(".subState").eq(this.index).addClass("subBg");
				$(".labsub").eq(this.index).addClass("labmove");
			}else {
				$(".subState").eq(this.index).removeClass("subBg");
				$(".labsub").eq(this.index).removeClass("labmove");
			}
		}
	}
}
//banner图
var swiper = new Swiper('.swiper-container', {
        pagination: '.swiper-pagination',
        nextButton: '.swiper-button-next',
        prevButton: '.swiper-button-prev',
        paginationClickable: true,
        spaceBetween: 30,
        centeredSlides: true,
        autoplay: 2500,
        loop: true,
        autoplayDisableOnInteraction: false
    });
//刷新加载
function refresh(para){
		  var opts = {
		  lines: 10, // 个数
		  length: 13, // 长度
		  width: 8, // 宽度
		  radius:12, // 圆周
		  corners: 1, // Corner roundness (0..1)
		  rotate: 0, // The rotation offset
		  direction: 1, // 1: clockwise, -1: counterclockwise
		  color: '#000', // #rgb or #rrggbb or array of colors
		  speed: 1, // Rounds per second
		  trail: 60, // Afterglow percentage
		  shadow: false, // Whether to render a shadow
		  hwaccel: false, // Whether to use hardware acceleration
		  className: 'spinner', // The CSS class to assign to the spinner
		  zIndex: 2e9, // The z-index (defaults to 2000000000)
		  top: 'auto', // Top position relative to parent in px
		  left: 'auto' // Left position relative to parent in px
		};
		var target = document.getElementById('foo');
		var spinner = new Spinner(opts).spin(target);  
}
                      

